Repository navigation
Conversation
The exception was passed as a list item rather than under the exception key, so logs lost the structured exception data.
…ling Two submissions of the same repository arriving together (e.g. a double click) both passed the uniqueness validation, and the second one then failed on the database unique index. The web form showed a generic "could not be saved" error and the create-package API returned a 500. Both now report that the package already exists.
The Check step already ignored repeat clicks, but the final Submit was a plain form post with no guard.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Submitting the same repository twice in quick succession (typically a double click on the final Submit button) could make both requests pass the "package already exists" validation. The second one then failed on the database's unique name index: the web form showed a generic "could not be saved" error, and
/api/create-packagereturned a 500.PackageController, which was passed as a list item instead of under theexceptionkey.Package creation moved into
PackageManager::create(), which is covered by tests for both the normal and the duplicate case. The controller paths themselves need a real VCS repository to resolve the package name, so they aren't covered by tests that avoid the network.